const state = {
  userName: '',
  tipDialogConfig: {
    show: false,
    title: '',
    content: '',
  }
}
const mutations = {
  SET_STATE(state, {key, value}) {
    state[key] = value
  },
  SET_USER_NAME(state, name) {
    state.userName = name
  }
}
const actions = {
  // 设置name
  setUserName({ commit }, name) {
    commit('SET_USER_NAME', name)
  }
}
export default {
  namespaced: true, // 调用commit('app/SET_STATE')
  state,
  mutations,
  actions
}
